#pragma once

namespace StillDesign
{
	namespace NvApi
	{
		public enum class Status
		{
			/// <summary>Success. Request is completed.</summary>
			Ok = NVAPI_OK,
			/// <summary>Generic error.</summary>
			Error = NVAPI_ERROR,
			/// <summary>NVAPI support library cannot be loaded.</summary>
			LibraryNotFound = NVAPI_LIBRARY_NOT_FOUND,
			/// <summary>not implemented in current driver installation</summary>
			NoImplementation = NVAPI_NO_IMPLEMENTATION,
			/// <summary>NvAPI_Initialize has not been called (successfully).</summary>
			ApiNotIntialized = NVAPI_API_NOT_INTIALIZED,
			/// <summary>The argument/parameter value is not valid or NULL.</summary>
			InvalidArgument = NVAPI_INVALID_ARGUMENT,
			/// <summary>No NVIDIA display driver, or NVIDIA GPU driving a display, was found.</summary>
			NvidiaDeviceNotFound = NVAPI_NVIDIA_DEVICE_NOT_FOUND,
			/// <summary>No more items to enumerate.</summary>
			EndEnumeration = NVAPI_END_ENUMERATION,
			/// <summary>Invalid handle.</summary>
			InvalidHandle = NVAPI_INVALID_HANDLE,
			/// <summary>An argument's structure version is not supported.</summary>
			IncompatibleStructVersion = NVAPI_INCOMPATIBLE_STRUCT_VERSION,
			/// <summary>The handle is no longer valid (likely due to GPU or display re-configuration).</summary>
			HandleInvalidated = NVAPI_HANDLE_INVALIDATED,
			/// <summary>No NVIDIA OpenGL context is current (but needs to be).</summary>
			OpenglContextNotCurrent = NVAPI_OPENGL_CONTEXT_NOT_CURRENT,
			/// <summary>OpenGL Expert is not supported by the current drivers.</summary>
			NoGlExpert = NVAPI_NO_GL_EXPERT,
			/// <summary>OpenGL Expert is supported, but driver instrumentation is currently disabled.</summary>
			InstrumentationDisabled = NVAPI_INSTRUMENTATION_DISABLED,
			/// <summary>Expected a logical GPU handle for one or more parameters.</summary>
			ExpectedLogicalGpuHandle = NVAPI_EXPECTED_LOGICAL_GPU_HANDLE,
			/// <summary>Expected a physical GPU handle for one or more parameters.</summary>
			ExpectedPhysicalGpuHandle = NVAPI_EXPECTED_PHYSICAL_GPU_HANDLE,
			/// <summary>Expected an NV display handle for one or more parameters.</summary>
			ExpectedDisplayHandle = NVAPI_EXPECTED_DISPLAY_HANDLE,
			/// <summary>The combination of parameters is not valid.</summary>
			InvalidCombination = NVAPI_INVALID_COMBINATION,
			/// <summary>Requested feature is not supported in the selected GPU.</summary>
			NotSupported = NVAPI_NOT_SUPPORTED,
			/// <summary>No port ID was found for the I2C transaction.</summary>
			PortidNotFound = NVAPI_PORTID_NOT_FOUND,
			/// <summary>Expected an unattached display handle as one of the input parameters.</summary>
			ExpectedUnattachedDisplayHandle = NVAPI_EXPECTED_UNATTACHED_DISPLAY_HANDLE,
			/// <summary>Invalid perf level.</summary>
			InvalidPerfLevel = NVAPI_INVALID_PERF_LEVEL,
			/// <summary>Device is busy; request not fulfilled.</summary>
			DeviceBusy = NVAPI_DEVICE_BUSY,
			/// <summary>NV persist file is not found.</summary>
			NvPersistFileNotFound = NVAPI_NV_PERSIST_FILE_NOT_FOUND,
			/// <summary>NV persist data is not found.</summary>
			PersistDataNotFound = NVAPI_PERSIST_DATA_NOT_FOUND,
			/// <summary>Expected a TV output display.</summary>
			ExpectedTvDisplay = NVAPI_EXPECTED_TV_DISPLAY,
			/// <summary>Expected a TV output on the D Connector - HDTV_EIAJ4120.</summary>
			ExpectedTvDisplayOnDconnector = NVAPI_EXPECTED_TV_DISPLAY_ON_DCONNECTOR,
			/// <summary>SLI is not active on this device.</summary>
			NoActiveSliTopology = NVAPI_NO_ACTIVE_SLI_TOPOLOGY,
			/// <summary>Setup of SLI rendering mode is not possible right now.</summary>
			SliRenderingModeNotallowed = NVAPI_SLI_RENDERING_MODE_NOTALLOWED,
			/// <summary>Expected a digital flat panel.</summary>
			ExpectedDigitalFlatPanel = NVAPI_EXPECTED_DIGITAL_FLAT_PANEL,
			/// <summary>Argument exceeds the expected size.</summary>
			ArgumentExceedMaxSize = NVAPI_ARGUMENT_EXCEED_MAX_SIZE,
			/// <summary>Inhibit is ON due to one of the flags in NV_GPU_DISPLAY_CHANGE_INHIBIT or SLI active.</summary>
			DeviceSwitchingNotAllowed = NVAPI_DEVICE_SWITCHING_NOT_ALLOWED,
			/// <summary>Testing of clocks is not supported.</summary>
			TestingClocksNotSupported = NVAPI_TESTING_CLOCKS_NOT_SUPPORTED,
			/// <summary>The specified underscan config is from an unknown source (e.g. INF).</summary>
			UnknownUnderscanConfig = NVAPI_UNKNOWN_UNDERSCAN_CONFIG,
			/// <summary>Timeout while reconfiguring GPUs.</summary>
			TimeoutReconfiguringGpuTopo = NVAPI_TIMEOUT_RECONFIGURING_GPU_TOPO,
			/// <summary>Requested data was not found.</summary>
			DataNotFound = NVAPI_DATA_NOT_FOUND,
			/// <summary>Expected an analog display.</summary>
			ExpectedAnalogDisplay = NVAPI_EXPECTED_ANALOG_DISPLAY,
			/// <summary>No SLI video bridge is present.</summary>
			NoVidlink = NVAPI_NO_VIDLINK,
			/// <summary>NVAPI requires a reboot for the settings to take effect.</summary>
			RequiresReboot = NVAPI_REQUIRES_REBOOT,
			/// <summary>The function is not supported with the current Hybrid mode.</summary>
			InvalidHybridMode = NVAPI_INVALID_HYBRID_MODE,
			/// <summary>The target types are not all the same.</summary>
			MixedTargetTypes = NVAPI_MIXED_TARGET_TYPES,
			/// <summary>The function is not supported from 32-bit on a 64-bit system.</summary>
			Syswow64NotSupported = NVAPI_SYSWOW64_NOT_SUPPORTED,
			/// <summary>There is no implicit GPU topology active. Use NVAPI_SetHybridMode to change topology.</summary>
			ImplicitSetGpuTopologyChangeNotAllowed = NVAPI_IMPLICIT_SET_GPU_TOPOLOGY_CHANGE_NOT_ALLOWED,
			/// <summary>Prompt the user to close all non-migratable applications.</summary>
			RequestUserToCloseNonMigratableApps = NVAPI_REQUEST_USER_TO_CLOSE_NON_MIGRATABLE_APPS,
			/// <summary>Could not allocate sufficient memory to complete the call.</summary>
			OutOfMemory = NVAPI_OUT_OF_MEMORY,
			/// <summary>The previous operation that is transferring information to or from this surface is incomplete.</summary>
			WasStillDrawing = NVAPI_WAS_STILL_DRAWING,
			/// <summary>The file was not found.</summary>
			FileNotFound = NVAPI_FILE_NOT_FOUND,
			/// <summary>There are too many unique instances of a particular type of state object.</summary>
			TooManyUniqueStateObjects = NVAPI_TOO_MANY_UNIQUE_STATE_OBJECTS,
			/// <summary>The method call is invalid. For example, a method's parameter may not be a valid pointer.</summary>
			InvalidCall = NVAPI_INVALID_CALL,
			/// <summary>d3d10_1.dll cannot be loaded.</summary>
			D3d101LibraryNotFound = NVAPI_D3D10_1_LIBRARY_NOT_FOUND,
			/// <summary>Couldn't find the function in the loaded DLL.</summary>
			FunctionNotFound = NVAPI_FUNCTION_NOT_FOUND
		};
		
		public enum class ThermalController
		{
			None = NVAPI_THERMAL_CONTROLLER_NONE,
			GpuInternal = NVAPI_THERMAL_CONTROLLER_GPU_INTERNAL,
			ADM1032 = NVAPI_THERMAL_CONTROLLER_ADM1032,
			MAX6649 = NVAPI_THERMAL_CONTROLLER_MAX6649,
			MAX1617 = NVAPI_THERMAL_CONTROLLER_MAX1617,
			LM99 = NVAPI_THERMAL_CONTROLLER_LM99,
			LM89 = NVAPI_THERMAL_CONTROLLER_LM89,
			LM64 = NVAPI_THERMAL_CONTROLLER_LM64,
			ADT7473 = NVAPI_THERMAL_CONTROLLER_ADT7473,
			SBMAX6649 = NVAPI_THERMAL_CONTROLLER_SBMAX6649,
			VBIOSEVT = NVAPI_THERMAL_CONTROLLER_VBIOSEVT,
			OS = NVAPI_THERMAL_CONTROLLER_OS,
			Unknown = NVAPI_THERMAL_CONTROLLER_UNKNOWN
		};
		public enum class ThermalTarget
		{
			None = NVAPI_THERMAL_TARGET_NONE,
			Gpu = NVAPI_THERMAL_TARGET_GPU,
			Memory = NVAPI_THERMAL_TARGET_MEMORY,
			PowerSupply = NVAPI_THERMAL_TARGET_POWER_SUPPLY,
			TargetBoard = NVAPI_THERMAL_TARGET_BOARD,
			All = NVAPI_THERMAL_TARGET_ALL,
			Unknown = NVAPI_THERMAL_TARGET_UNKNOWN
		};
		
		public enum class GpuBusType
		{
			Undefined = NVAPI_GPU_BUS_TYPE_UNDEFINED,
			Pci = NVAPI_GPU_BUS_TYPE_PCI,
			Agp = NVAPI_GPU_BUS_TYPE_AGP,
			PciExpress = NVAPI_GPU_BUS_TYPE_PCI_EXPRESS,
			Fpci = NVAPI_GPU_BUS_TYPE_FPCI
		};
		
		public enum class GpuConnectorType
		{
			Vga15Pin = NVAPI_GPU_CONNECTOR_VGA_15_PIN,
			Composite = NVAPI_GPU_CONNECTOR_TV_COMPOSITE,
			SVideo = NVAPI_GPU_CONNECTOR_TV_SVIDEO,
			HdtvComponent = NVAPI_GPU_CONNECTOR_TV_HDTV_COMPONENT,
			Scart = NVAPI_GPU_CONNECTOR_TV_SCART,
			ScartOnEiaj4120 = NVAPI_GPU_CONNECTOR_TV_COMPOSITE_SCART_ON_EIAJ4120,
			HdtvEiaj4120 = NVAPI_GPU_CONNECTOR_TV_HDTV_EIAJ4120,
			HdtvYprpb = NVAPI_GPU_CONNECTOR_PC_POD_HDTV_YPRPB,
			PcPodSVideo = NVAPI_GPU_CONNECTOR_PC_POD_SVIDEO,
			PcPodComposite = NVAPI_GPU_CONNECTOR_PC_POD_COMPOSITE,
			DviITvSVideo = NVAPI_GPU_CONNECTOR_DVI_I_TV_SVIDEO,
			DviITvComposite = NVAPI_GPU_CONNECTOR_DVI_I_TV_COMPOSITE,
			DviI = NVAPI_GPU_CONNECTOR_DVI_I,
			DviD = NVAPI_GPU_CONNECTOR_DVI_D,
			Adc = NVAPI_GPU_CONNECTOR_ADC,
			LfhDviI1 = NVAPI_GPU_CONNECTOR_LFH_DVI_I_1,
			DviI2 = NVAPI_GPU_CONNECTOR_LFH_DVI_I_2,
			Spwg = NVAPI_GPU_CONNECTOR_SPWG,
			Oem = NVAPI_GPU_CONNECTOR_OEM,
			DisplayPortExternal = NVAPI_GPU_CONNECTOR_DISPLAYPORT_EXTERNAL,
			DisplayPortInternal = NVAPI_GPU_CONNECTOR_DISPLAYPORT_INTERNAL,
			HdmiA = NVAPI_GPU_CONNECTOR_HDMI_A,
			Unknown = NVAPI_GPU_CONNECTOR_UNKNOWN
		};
		
		public enum class GpuOutputType
		{
			Unknown = NVAPI_GPU_OUTPUT_UNKNOWN,
			Crt = NVAPI_GPU_OUTPUT_CRT,
			DigitalFlatPanel = NVAPI_GPU_OUTPUT_DFP,
			Tv = NVAPI_GPU_OUTPUT_TV
		};

		public enum class GpuType
		{
			Unknown = NV_SYSTEM_TYPE_GPU_UNKNOWN,
			IGpu = NV_SYSTEM_TYPE_IGPU,
			DGpu = NV_SYSTEM_TYPE_DGPU,
		};
		
		public enum class SystemType
		{
			Unknown = NV_SYSTEM_TYPE_UNKNOWN,
			Laptop = NV_SYSTEM_TYPE_LAPTOP,
			Desktop = NV_SYSTEM_TYPE_DESKTOP
		};
	}
}